import java.io.File;

public class ReturnDigestUserInterface 
{
	public static void main(String[] args) 
	{
		for(int i=0;i<args.length;i++)
		{
			File f = new File(args[i]);
			ReturnDigest dr = new ReturnDigest(f);
			dr.start();
			
			StringBuffer result = new StringBuffer(f.toString());
			result.append(": ");
			byte[] digest = dr.getDigest();
			
//			System.out.println("digest.length = " + digest.length);
			for(int j=0;j<digest.length;j++)
			{
				result.append(digest[j]+" ");
			}
			System.out.println(result);
		}
	}
}
